import { api, cdn,post } from '@/utils/request';

export const uploadUrl = `${api}/szjc-ai/file`;
export const uploadUrlBotId = (botId: string) => `${api}/szjc-ai/file?botId=${botId}`;
export const uploadXlsxBotId = (botId: string) => `${api}/szjc-ai/common/importXlsx?botId=${botId}`;

// export const fileUrlGet = (key: string) => `${api}/common/file?key=${encodeURIComponent(key)}`;
export const fileUrlGet = (key: string) => `${cdn}/${key}`;

export const uploadFileGet = (filePath: string) => `https://cdn.henanyuexue.com/${filePath}`;

// 判断文件是否为空 api/szjc-ai/common/isEmpty
export const isEmptyFile = (data: any) => post(`${api}/common/isEmpty`, data);

// oss获取地址
// export const ossGetImg = `${cdn}?filePath=`;
export const ossGetImg = '';
// 模板
export const mubanUrl =
  'https://ai.huazhiqing.com/api/aigc/common/ossfile?filePath=aigc_team/content/f/b9/fb945a96f085bbe1b5680d0d989bb747.xlsx';
export const mubanXlsxUrl =
  'https://ai.huazhiqing.com/api/aigc/common/ossfile?filePath=aigc_team/content/f/b9/fb945a96f085bbe1b5680d0d989bb747.xlsx';
export const mubanDocxUrl =
  'https://ai.huazhiqing.com/api/aigc/common/ossfile?filePath=english/content/d/37/d372bfa87110964ff0bcdb348313d7f7.docx';

export const mubanCjd = fileUrlGet('cdn/szjc-ai/学生成绩单模板.xlsx');
